import VueRouter from 'vue-router'
//导入路由组件
import HomeContainer from '../components/tabbar/HomeContainer.vue'
import MemberContainer from '../components/tabbar/MemberContainer.vue'
import SearchContainer from '../components/tabbar/SearchContainer.vue'
import ShopcarContainer from '../components/tabbar/ShopcarContainer.vue'
import NewsList from '../components/news/Newslist.vue'
import NwesInfo from '../components/news/NewsInfo.vue'
import ImgList from '../components/imglist/ImgList.vue'
import ImgInfo from '../components/imglist/ImgInfo.vue'
import Goods from '../components/Production/GoodsList.vue'
import GoodsInfo from '../components/Production/GoodsInfo.vue'
import GoodsDesc from '../components/Production/GoodsDesc.vue'
import GoodsCmt from '../components/Production/GoodsCmt.vue'
var router= new VueRouter({
  routes:[
    { path: '/',redirect:'/home'},
    { path: '/home',component: HomeContainer },
    { path: '/member',component: MemberContainer },
    { path: '/search',component: SearchContainer},
    { path: '/shopcar',component: ShopcarContainer},
    { path: '/home/newslist',component:NewsList},
    { path: '/home/newslist/newsinfo/:id', component:NwesInfo },
    { path: '/home/images',component:ImgList},
    { path: '/home/images/imginfo/:id',component:ImgInfo},
    { path: '/home/goods',component:Goods},
    { path: '/home/goods/goodsInfo/:id',component:GoodsInfo},
    { path: '/home/goods/goodsdesc/:id',component:GoodsDesc ,name:'goodsdesc'},
    { path: '/home/goods/goodscomment/:id',component:GoodsCmt ,name:'goodscmt'}
],
  linkActiveClass:'mui-active'
})
export default router
